package org.javaboy.demo;

import org.springframework.context.annotation.AnnotationConfigApplicationContext;

public class JavaDemo {
    public static void main(String[] args) {
        AnnotationConfigApplicationContext ctx = new AnnotationConfigApplicationContext(JavaConfig.class);
        User u1 = ctx.getBean(User.class);
        User u2 = ctx.getBean(User.class);
        System.out.println(u1 == u2);
    }
}
